extends layout

block content
  include includes/navbar.pug
  h1 Instagram
  .row
    .col-12.col-md-8
      .card.mb-1.mt-1
        .card-body
          form(action="/images/",method="post",enctype="multipart/form-data")
            .form-group.row
              label.col-12.col-md-2 Throughs
              input.col-12.col-md-10.form-control-file(type="file",name='imgfile')
            .form-group.row
              label.col-12.col-md-2 Title
              input.col-12.col-md-10.form-control(type="text",name='title')
            .form-group.row
              label.col-12.col-md-2 Description
              input.col-12.col-md-10.form-control(type="text",name='description')
            .form-group.row
              .col-12.offset-md-8.col-md-4
                button.btn.btn-primary.btn-block(type='submit') Submit
    .col-12.col-md-4
      include includes/stats.pug
  .row
    .col-12.col-md-8
      .row
        each image in images
          a.col-6.col-md-4#throughs-btn(data-imageid=_id)(href=`/images/${image._id}`)
            .card
                img.card-img-top(src=`/uploads/${image.diskfilename}`,alt=image.title)
                .card-body
                  h5.card-title= image.title
                  p.card-text= image.description
                  p.card-text= 'Pet Name: '+image.nickname
    .col-12.col-md-4
      include includes/comment.pug
  include includes/footer.pug
    //- script(src="/javascripts/show.js")
    script(src="/javascripts/TweenLite.min.js")
    script(src="/javascripts/three.min.js")
    script(src="/javascripts/rAF.js")
    script(src="/javascripts/one.js")
    //- script(src="/javascripts/index.js")
    script(src="/javascripts/html5.js")
    script(src="/javascripts/EasePack.min.js")
    //- script(src="/javascripts/demo-1.js")
    //- script(src="/javascripts/bootstrap.min.js")
    script(src="/javascripts/text.js")
